#!/bin/bash

# 设置环境变量
source set_env.sh

export TP_SIZE=2
export PP_SIZE=8

export HF_MODEL_PATH=/home/ma-user/work/models/hf_models/Qwen/Qwen2.5-32B
export MG_MODEL_PATH=/home/ma-user/work/models/mg_models/Qwen/Qwen2.5-32B-tp${TP_SIZE}-pp${PP_SIZE}

# export HF_MODEL_PATH=/home/ma-user/work/models/hf_models/Qwen/Qwen2.5-7B-Instruct
# export MG_MODEL_PATH=/home/ma-user/work/models/mg_models/Qwen/Qwen2.5-7B-Instruct$([ $TP_SIZE != 1 ] && echo "-tp${TP_SIZE}")$([ $PP_SIZE != 1 ] && echo "-pp${PP_SIZE}")

echo HF_MODEL_PATH=$HF_MODEL_PATH
echo MG_MODEL_PATH=$MG_MODEL_PATH

# 可以更换模型处理脚本，但记得修改其脚本，通过环境变量获取tp_size和tp_size
bash examples/mcore/qwen2/ckpt_convert_qwen2_hf2mcore.sh
